package com.recommender;

import com.model.StructuredContextDataModel;
import com.similarity.ContextSimilarity;


public abstract class StructuredContextRecommender implements Recommender{
	
	private ContextSimilarity contextSimilarity;
	protected ContextSimilarity cSim;
	protected StructuredContextDataModel genericmodel;

		
	protected float getRankings(int imageID,String contextvariable,String contextvalue)
	{
		int frequency=0;
		try {
			frequency = genericmodel.getImageFrequency(contextvariable, contextvalue, imageID);
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		float rank=1+0.04f*frequency;
		return rank;
	}


	
	
}
